//
// Created by Admin on 2021/9/22.
//

#ifndef PRACTISE7_MY_STACK_H
#define PRACTISE7_MY_STACK_H
#include <stdio.h>
#include <stdlib.h>

enum {
    number,character
};

typedef struct Item{
    int type;
    int value;
    struct Item* prev;
}Item,*pItem;

typedef struct {
    //栈底指针
    pItem ebp;
    //栈顶指针
    pItem esp;
}Stack,*pStack;

pStack make_stack();
void destroy_stack(pStack stack);
void push(pStack stack,pItem item);
pItem peek(pStack stack);
int pop(pStack stack);
void printStackTrace(pStack stack);

#endif //PRACTISE7_MY_STACK_H
